/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Logic;

/**
 *
 * @author Ramiro
 */
public class Fecha {
    
    private String dia = "";
    private String mes = "";
    private String anio = "";

    Fecha(String fecha) {
        this.dia = fecha.substring(0,2);
        this.mes = fecha.substring(2, 4);
        this.anio = fecha.substring(4, fecha.length());
    }
    
    
    Fecha(){
        this.dia = "00";
        this.mes = "00";
        this.anio = "0000";
    }
    

    public void setDia(String dia) {
        this.dia = dia;
    }

    public void setMes(String mes) {
        this.mes = mes;
    }

    public void setAnio(String anio) {
        this.anio = anio;
    }

    public String getDia() {
        return dia;
    }

    public String getMes() {
        return mes;
    }

    public String getAnio() {
        return anio;
    }
    
    
    @Override
    public String toString (){
        return dia + "-" + mes + "-" + anio;
       
    }
}
